//
//  AboutJiukuViewController.m
//  JiuKuGospel
//
//  Created by jiukuyinyue on 15-9-1.
//  Copyright (c) 2015年 JiuKuForApp. All rights reserved.
//

#import "AboutJiukuViewController.h"
#import "SuggestMessageViewController.h"
@interface AboutJiukuViewController ()

@end

@implementation AboutJiukuViewController



- (BOOL)canBecomeFirstResponder{
    return YES;
}
- (void)viewDidLoad {
    [super viewDidLoad];
    self.title = @"关于";
    self.view.backgroundColor = RGBColor(227, 227,227);
    [self setupUI];
}

- (void)leftBtnAction
{
    [self.navigationController popViewControllerAnimated:YES];
}

- (void)setupUI
{
    UIImageView * titleImageView = [[UIImageView alloc] initWithFrame:CGRectMake(0, 0, self.view.width / 5.0, self.view.width / 5.0)];
    titleImageView.image = [UIImage imageNamed:@"AppIcon"];
    titleImageView.center = CGPointMake(self.view.center.x,titleImageView.width / 2.0 + 64+50);
    [self.view addSubview:titleImageView];
    
    UILabel * titleLabel = [[UILabel alloc] initWithFrame:CGRectMake(titleImageView.left-10, titleImageView.bottom, titleImageView.width+20, 30)];
    titleLabel.text = @"九酷云头条";
    titleLabel.textAlignment = NSTextAlignmentCenter;
    titleLabel.font = [UIFont systemFontOfSize:16];
    titleLabel.textColor = [UIColor blackColor];
    [self.view addSubview:titleLabel];
    
    UILabel * bundleVSLabel = [[UILabel alloc] initWithFrame:CGRectMake(0, titleLabel.bottom+10, self.view.width, 30)];
    bundleVSLabel.textAlignment = NSTextAlignmentCenter;
    bundleVSLabel.textColor = [UIColor blackColor];
    bundleVSLabel.font = FONT_14;
    NSDictionary * infoDic = [[NSBundle mainBundle] infoDictionary];
    CFShow((__bridge CFTypeRef)(infoDic));
    NSString * appVersion = [infoDic objectForKey:@"CFBundleShortVersionString"];
    bundleVSLabel.text = [NSString stringWithFormat:@"当前版本号: V %@", appVersion];
    [self.view addSubview:bundleVSLabel];

    UIButton * suggestBtn = [UIButton buttonWithType:UIButtonTypeCustom];
    suggestBtn.frame = CGRectMake(0, bundleVSLabel.bottom+15, self.view.width, 44);
    suggestBtn.backgroundColor = JK_HUISE_LINE_COLOR;
    [suggestBtn setTitle:@"用户反馈" forState:UIControlStateNormal];
    [suggestBtn setTitleColor:[UIColor blackColor] forState:UIControlStateNormal];
    [suggestBtn addTarget:self action:@selector(pushSuggestVC) forControlEvents:UIControlEventTouchUpInside];
    [self.view addSubview:suggestBtn];
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

- (void)pushSuggestVC
{
    SuggestMessageViewController * suggestVC = [[SuggestMessageViewController alloc] init];
    [self.navigationController pushViewController:suggestVC animated:YES];
}

 

@end
